/*
 * Copyright (C) 2023 xuexiangjys(xuexiangjys@163.com)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 */

package com.xuexiang.templateproject.bean;
//
//import anet.channel.strategy.dispatch.DispatchConstants;
//import com.jcds.common.utils.Constants;
import kotlin.Metadata;
import kotlin.jvm.internal.Intrinsics;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

public final class ChildEntity {
    private final int grade;
    @NotNull
    private final String gradeName;
    private final int id;
    @NotNull
    private final String username;

    public ChildEntity(int i2, @NotNull String username, int i3, @NotNull String gradeName) {
        Intrinsics.checkNotNullParameter(username, "username");
        Intrinsics.checkNotNullParameter(gradeName, "gradeName");
        this.id = i2;
        this.username = username;
        this.grade = i3;
        this.gradeName = gradeName;
    }

    public static /* synthetic */ ChildEntity copy$default(ChildEntity childEntity, int i2, String str, int i3, String str2, int i4, Object obj) {
        if ((i4 & 1) != 0) {
            i2 = childEntity.id;
        }
        if ((i4 & 2) != 0) {
            str = childEntity.username;
        }
        if ((i4 & 4) != 0) {
            i3 = childEntity.grade;
        }
        if ((i4 & 8) != 0) {
            str2 = childEntity.gradeName;
        }
        return childEntity.copy(i2, str, i3, str2);
    }

    public final int component1() {
        return this.id;
    }

    @NotNull
    public final String component2() {
        return this.username;
    }

    public final int component3() {
        return this.grade;
    }

    @NotNull
    public final String component4() {
        return this.gradeName;
    }

    @NotNull
    public final ChildEntity copy(int i2, @NotNull String username, int i3, @NotNull String gradeName) {
        Intrinsics.checkNotNullParameter(username, "username");
        Intrinsics.checkNotNullParameter(gradeName, "gradeName");
        return new ChildEntity(i2, username, i3, gradeName);
    }

    public boolean equals(@Nullable Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof ChildEntity)) {
            return false;
        }
        ChildEntity childEntity = (ChildEntity) obj;
        return this.id == childEntity.id && Intrinsics.areEqual(this.username, childEntity.username) && this.grade == childEntity.grade && Intrinsics.areEqual(this.gradeName, childEntity.gradeName);
    }

    public final int getGrade() {
        return this.grade;
    }

    @NotNull
    public final String getGradeName() {
        return this.gradeName;
    }

    public final int getId() {
        return this.id;
    }

    @NotNull
    public final String getUsername() {
        return this.username;
    }

    public int hashCode() {
        return (((((this.id * 31) + this.username.hashCode()) * 31) + this.grade) * 31) + this.gradeName.hashCode();
    }

    @NotNull
    public String toString() {
        return "ChildEntity(id=" + this.id + ", username=" + this.username + ", grade=" + this.grade + ", gradeName=" + this.gradeName + ')';
    }
}